package com.dodock.banglapapers.server;

import java.io.IOException;
import javax.servlet.http.*;

import com.google.gson.JsonArray;
import com.google.gson.JsonObject;


@SuppressWarnings("serial")
public class DoDockNewsServlet extends HttpServlet {
	public void doGet(HttpServletRequest req, HttpServletResponse resp)
			throws IOException {
		resp.setContentType("application/json");
		
		JsonObject prothomalo = new JsonObject();
		prothomalo.addProperty("id", "prothomalo");
		prothomalo.addProperty("logo", "prothomalo.png");
		
		JsonObject bdnews = new JsonObject();
		bdnews.addProperty("id", "bdnews");
		bdnews.addProperty("logo", "bdnews.png");
		
		JsonArray newsPapers = new JsonArray();
		newsPapers.add(prothomalo);
		newsPapers.add(bdnews);
	
		
		resp.getWriter().print(newsPapers.toString());
	}
}
